<template>
  <div class="requirementInfo-component">
    <div v-if="detailData" class="info-container">
      <el-form ref="elForm" :model="detailData" size="small" label-width="160px">
        <item-title title="项目概况" />
        <el-row
          :gutter="15"
          class="form-row01"
          style="margin-left:0px;margin-right:0px;display:flex;justify-content:flex-start;flex-wrap:wrap;"
        >
          <el-form-item label="项目来源：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.project_source||"无" }}</div>
          </el-form-item>
          <el-form-item v-if="detailData.demand_idea_name" label="关联项目课题：" style="width:33.333%;">
            <div class="tag-container"><el-button type="text" size="medium" class="tag-hover text-line-1" style="padding: 8px 0px" @click="toRequireDetail">{{ detailData.demand_idea_name }}</el-button></div>
          </el-form-item>
          <el-form-item label="审批编号：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.info_check?detailData.info_check.SerialNumber:"无" }}</div>
          </el-form-item>
          <el-form-item label="项目编号：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.project_no||"无" }}</div>
          </el-form-item>
          <el-form-item v-if="detailData.project_source_id==='1'" label="自研立项信息：" style="width:33.333%;">
            <div class="text-line-2"><el-link type="primary" :underline="false" @click="toSelfProject">{{ detailData.demand_info_project_name||"无" }}</el-link></div>
          </el-form-item>
          <el-form-item label="项目名称：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.project_name||"无" }}</div>
          </el-form-item>
          <el-form-item label="项目类型：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.project_type||"无" }}</div>
          </el-form-item>
          <el-form-item label="申报类别：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.apply_type||"无" }}</div>
          </el-form-item>
          <el-form-item label="剂型与规格：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.dosage_norms||"无" }}</div>
          </el-form-item>
          <el-form-item label="药物类别：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.medical_type||"无" }}</div>
          </el-form-item>
          <el-form-item label="药物成分：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.medical_ingredient||"无" }}</div>
          </el-form-item>
          <el-form-item label="功能与主治：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.function_attending||"无" }}</div>
          </el-form-item>
          <el-form-item label="用法用量：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.usage_num||"无" }}</div>
          </el-form-item>
          <el-form-item label="疗程：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.treatment||"无" }}</div>
          </el-form-item>
          <el-form-item label="项目目标：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.project_goal||"无" }}</div>
          </el-form-item>
          <el-form-item label="项目质量标准来源：" style="width:33.333%;">
            <div class="text-line-2">{{ detailData.quality_source||"无" }}</div>
          </el-form-item>
        </el-row>

        <item-title title="项目可行性分析" />
        <el-row :gutter="15" style="margin-left:0px;margin-right:0px;">
          <el-form-item label="项目优势：">
            <div>{{ detailData.project_advantage||"无" }}</div>
          </el-form-item>
          <el-form-item label="国外研发情况：">
            <div>{{ detailData.abroad_research||"无" }}</div>
          </el-form-item>
          <el-form-item label="国内研发情况：">
            <div>{{ detailData.internal_research||"无" }}</div>
          </el-form-item>
          <el-form-item label="市场分析：">
            <div>{{ detailData.market_analysis||"无" }}</div>
          </el-form-item>
          <el-form-item label="临床前支出预算：">
            <div>{{ detailData.budget_before||"无" }}</div>
          </el-form-item>
          <el-form-item label="临床支出预算：">
            <div>{{ detailData.budget||"无" }}</div>
          </el-form-item>
          <el-form-item label="对照药（对照情况）：">
            <div>{{ detailData.contrast_medical_info||"无" }}</div>
          </el-form-item>
          <el-form-item label="产权：">
            <div>{{ detailData.equity||"无" }}</div>
          </el-form-item>
          <el-form-item label="申请建议：">
            <div>{{ detailData.apply_advice||"无" }}</div>
          </el-form-item>
          <el-form-item label="注意事项：">
            <div>{{ detailData.notice||"无" }}</div>
          </el-form-item>
          <el-form-item label="备注：">
            <div>{{ detailData.remark||"无" }}</div>
          </el-form-item>
        </el-row>
      </el-form>
    </div>
  </div>
</template>

<script>
export default {
  props: {
    detailData: {
      type: Object,
      default: () => {}
    }
  },
  data() {
    return {

    }
  },

  // 生命周期 - 创建完成（访问当前this实例）
  created() {},
  methods: {
    toRequireDetail() {
      if (this.checkDetailPermis(['demand:require'])) {
        this.$router.push({
          name: 'requirementDetail',
          query: {
            requireId: this.detailData.demand_idea_id
          }
        })
      }
    },
    toSelfProject() {
      if (this.checkDetailPermis(['project:my:list'])) {
        this.$router.push({
          name: 'projectDetail',
          query: {
            projectId: this.detailData.demand_info_id
          }
        })
      }
    }
  }
}
</script>
<style lang="scss" scoped>
/* @import url(); 引入css类 */
@import "@/assets/scss/views/projectInfomation/details/modules/baseInfo.scss";
</style>
